/*
 * HeresyoriginsView.java
 */

package heresyorigins;

import org.jdesktop.application.Action;
import org.jdesktop.application.ResourceMap;
import org.jdesktop.application.SingleFrameApplication;
import org.jdesktop.application.FrameView;
import org.jdesktop.application.TaskMonitor;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.AbstractButton;
import javax.swing.ButtonModel;
import javax.swing.Timer;
import javax.swing.Icon;
import javax.swing.JDialog;
import javax.swing.JFrame;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;

/**
 * The application's main frame.
 */
public class HeresyoriginsView extends FrameView {

    ChangeListener changeListener = new ChangeListener() {
      public void stateChanged(ChangeEvent changeEvent) {
        AbstractButton abstractButton = (AbstractButton) changeEvent
            .getSource();
        ButtonModel buttonModel = abstractButton.getModel();
        //boolean armed = buttonModel.isArmed();
        //boolean pressed = buttonModel.isPressed();
        //boolean selected = buttonModel.isSelected();
        //System.out.println("Changed: " + armed + "/" + pressed + "/" + selected);
        recalculate();
      }
    };

    public HeresyoriginsView(SingleFrameApplication app) {
        super(app);

        initComponents();

        // status bar initialization - message timeout, idle icon and busy animation, etc
        ResourceMap resourceMap = getResourceMap();
        int messageTimeout = resourceMap.getInteger("StatusBar.messageTimeout");
        messageTimer = new Timer(messageTimeout, new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                statusMessageLabel.setText("");
            }
        });
        messageTimer.setRepeats(false);
        int busyAnimationRate = resourceMap.getInteger("StatusBar.busyAnimationRate");
        for (int i = 0; i < busyIcons.length; i++) {
            busyIcons[i] = resourceMap.getIcon("StatusBar.busyIcons[" + i + "]");
        }
        busyIconTimer = new Timer(busyAnimationRate, new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                busyIconIndex = (busyIconIndex + 1) % busyIcons.length;
                statusAnimationLabel.setIcon(busyIcons[busyIconIndex]);
            }
        });
        idleIcon = resourceMap.getIcon("StatusBar.idleIcon");
        statusAnimationLabel.setIcon(idleIcon);
        progressBar.setVisible(false);

        // connecting action tasks to status bar via TaskMonitor
        TaskMonitor taskMonitor = new TaskMonitor(getApplication().getContext());
        taskMonitor.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
            public void propertyChange(java.beans.PropertyChangeEvent evt) {
                String propertyName = evt.getPropertyName();
                if ("started".equals(propertyName)) {
                    if (!busyIconTimer.isRunning()) {
                        statusAnimationLabel.setIcon(busyIcons[0]);
                        busyIconIndex = 0;
                        busyIconTimer.start();
                    }
                    progressBar.setVisible(true);
                    progressBar.setIndeterminate(true);
                } else if ("done".equals(propertyName)) {
                    busyIconTimer.stop();
                    statusAnimationLabel.setIcon(idleIcon);
                    progressBar.setVisible(false);
                    progressBar.setValue(0);
                } else if ("message".equals(propertyName)) {
                    String text = (String)(evt.getNewValue());
                    statusMessageLabel.setText((text == null) ? "" : text);
                    messageTimer.restart();
                } else if ("progress".equals(propertyName)) {
                    int value = (Integer)(evt.getNewValue());
                    progressBar.setVisible(true);
                    progressBar.setIndeterminate(false);
                    progressBar.setValue(value);
                }
            }
        });
    }

    @Action
    public void showAboutBox() {
        if (aboutBox == null) {
            JFrame mainFrame = HeresyoriginsApp.getApplication().getMainFrame();
            aboutBox = new HeresyoriginsAboutBox(mainFrame);
            aboutBox.setLocationRelativeTo(mainFrame);
        }
        HeresyoriginsApp.getApplication().show(aboutBox);
    }
    @Action
    public void recalculate(){
     jTextArea1.setText("");
     PathSummaryText.setText("");
     OriginPath.resetCS();
     OriginPath.resetSkills();
     
     if (DeathWorldButton.isSelected()) {
        jTextArea1.append("Death World - ");
        PathSummaryText.append(Homeworld.DeathWorld.getDesc());
        OriginPath.CharScore.S.addCharValue(5);
        OriginPath.CharScore.T.addCharValue(5);
        OriginPath.CharScore.WP.addCharValue(-5);
        OriginPath.CharScore.Fel.addCharValue(-5);
        OriginPath.Skill.Survival.addSkillLevel();
        }
     if (VoidBornButton.isSelected()) {
         jTextArea1.append("Void Born - ");
        PathSummaryText.append(Homeworld.VoidBorn.getDesc());
        OriginPath.CharScore.S.addCharValue(-5);
        OriginPath.CharScore.WP.addCharValue(+5);
     }
     if (ForgeWorldButton.isSelected()){
         jTextArea1.append("Forge World - ");
        PathSummaryText.append(Homeworld.ForgeWorld.getDesc());
        OriginPath.CharScore.WS.addCharValue(-5);
        OriginPath.CharScore.Int.addCharValue(5);
     }
     if (HiveWorldButton.isSelected()){
         jTextArea1.append("Hive World - ");
        PathSummaryText.append(Homeworld.HiveWorld.getDesc());
     }
     if (ImperialWorldButton.isSelected()){
         jTextArea1.append("Imperial World - ");
       PathSummaryText.append(Homeworld.ImperialWorld.getDesc());
     }
     if (NobleBornButton.isSelected()){
         jTextArea1.append("Noble Born -  ");
        PathSummaryText.append(Homeworld.NobleBorn.getDesc());
        //OriginPath.Option.setOption("Noble");
     }
     if (ScavengerButton.isSelected()) jTextArea1.append("Scavenger -  ");
     if (ScapegraceButton.isSelected()) jTextArea1.append("Scapegrace -  ");
     if (StubjackButton.isSelected()) jTextArea1.append("Stubjack -  ");
     if (ChildOfTheCreedButton.isSelected()) jTextArea1.append("Child Of The Creed -  ");
     if (SavantButton.isSelected()) jTextArea1.append("Savant -  ");
     if (VauntedButton.isSelected()) jTextArea1.append("Vaunted -  ");
     if (TaintedButton.isSelected()) jTextArea1.append("Tainted -  ");
     if (CriminalButton.isSelected()) jTextArea1.append("Criminal -  ");
     if (RenegadeButton.isSelected()) jTextArea1.append("Renegade -  ");
     if (DutyBoundButton.isSelected()) jTextArea1.append("Duty Bound -  ");
     if (ZealotButton.isSelected()) jTextArea1.append("Zealot -  ");
     if (ChosenByDestinyButton.isSelected()) jTextArea1.append("Chosen By Destiny -  ");
     if (TheHandOfWarButton.isSelected()) jTextArea1.append("The Hand Of War -  ");
     if (PressGangnedButton.isSelected()) jTextArea1.append("Press-Gangned -  ");
     if (CalamityButton.isSelected()) jTextArea1.append("Calamity -  ");
     if (ShipLornButton.isSelected()) jTextArea1.append("Ship-Lorn -  ");
     if (DarkVoyageButton.isSelected()) jTextArea1.append("Dark Voyage -  ");
     if (HighVendettaButton.isSelected()) jTextArea1.append("High Vendetta -  ");
     if (EnduranceButton.isSelected()) jTextArea1.append("Endurance -  ");
     if (FortuneButton.isSelected()) jTextArea1.append("Fortune -  ");
     if (VengeanceButton.isSelected()) jTextArea1.append("Vengeance -  ");
     if (RenownButton.isSelected()) jTextArea1.append("Renown -  ");
     if (PrideButton.isSelected()) jTextArea1.append("Pride -  ");
     if (PrestigeButton.isSelected()) jTextArea1.append("Prestige -  ");
     if (AstropathTranscendentButton.isSelected()) jTextArea1.append("Astropath Transcendent ");
     if (ArchMillitantButton.isSelected()) jTextArea1.append("Arch-Millitant ");
     if (VoidMasterButton.isSelected()) jTextArea1.append("Void-Master ");
     if (ExploratorButton.isSelected()) jTextArea1.append("Explorator ");
     if (MissionaryButton.isSelected()) jTextArea1.append("Missionary ");
     if (SeneschalButton.isSelected()) jTextArea1.append("Seneschal ");
     if (NavigatorButton.isSelected()) jTextArea1.append("Navigator ");
     if (RogueTraderButton.isSelected()) jTextArea1.append("Rogue Trader ");
     //if (.isSelected()) jTextArea1.append(" -  ");
    CharacterSummaryText.setText("");
    //CharacterSummaryText.setText(OriginPath.CharScore.getAllChar());
    for (OriginPath.CharScore c : OriginPath.CharScore.values())
        CharacterSummaryText.append(c.name()+":"+c.getCharValue()+" ");
    for (OriginPath.Skill s : OriginPath.Skill.values())
        if (s.getSkillLevel() !=0 ) CharacterSummaryText.append(s.name()+" "+s.getSkillText());

    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        mainPanel = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jTextArea1 = new javax.swing.JTextArea();
        OriginPathLabel = new javax.swing.JLabel();
        jLabel2 = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        PathSummaryText = new javax.swing.JTextArea();
        jScrollPane3 = new javax.swing.JScrollPane();
        CharacterSummaryText = new javax.swing.JTextArea();
        CharacterSummaryLabel = new javax.swing.JLabel();
        ButtonPanel = new javax.swing.JPanel();
        HiveWorldButton = new javax.swing.JToggleButton();
        RogueTraderButton = new javax.swing.JToggleButton();
        VauntedButton = new javax.swing.JToggleButton();
        CriminalButton = new javax.swing.JToggleButton();
        DarkVoyageButton = new javax.swing.JToggleButton();
        TaintedButton = new javax.swing.JToggleButton();
        ArchMillitantButton = new javax.swing.JToggleButton();
        ExploratorButton = new javax.swing.JToggleButton();
        FortuneButton = new javax.swing.JToggleButton();
        HighVendettaButton = new javax.swing.JToggleButton();
        PrideButton = new javax.swing.JToggleButton();
        AstropathTranscendentButton = new javax.swing.JToggleButton();
        VengeanceButton = new javax.swing.JToggleButton();
        TheHandOfWarButton = new javax.swing.JToggleButton();
        NavigatorButton = new javax.swing.JToggleButton();
        NobleBornButton = new javax.swing.JToggleButton();
        VoidBornButton = new javax.swing.JToggleButton();
        SavantButton = new javax.swing.JToggleButton();
        PressGangnedButton = new javax.swing.JToggleButton();
        ChildOfTheCreedButton = new javax.swing.JToggleButton();
        DeathWorldButton = new javax.swing.JToggleButton();
        StubjackButton = new javax.swing.JToggleButton();
        ShipLornButton = new javax.swing.JToggleButton();
        RenegadeButton = new javax.swing.JToggleButton();
        CalamityButton = new javax.swing.JToggleButton();
        ScapegraceButton = new javax.swing.JToggleButton();
        SeneschalButton = new javax.swing.JToggleButton();
        RenownButton = new javax.swing.JToggleButton();
        ScavengerButton = new javax.swing.JToggleButton();
        DutyBoundButton = new javax.swing.JToggleButton();
        PrestigeButton = new javax.swing.JToggleButton();
        ImperialWorldButton = new javax.swing.JToggleButton();
        VoidMasterButton = new javax.swing.JToggleButton();
        ZealotButton = new javax.swing.JToggleButton();
        ChosenByDestinyButton = new javax.swing.JToggleButton();
        MissionaryButton = new javax.swing.JToggleButton();
        ForgeWorldButton = new javax.swing.JToggleButton();
        EnduranceButton = new javax.swing.JToggleButton();
        OptionsButton = new javax.swing.JButton();
        menuBar = new javax.swing.JMenuBar();
        javax.swing.JMenu fileMenu = new javax.swing.JMenu();
        ListM = new javax.swing.JMenuItem();
        javax.swing.JMenuItem exitMenuItem = new javax.swing.JMenuItem();
        javax.swing.JMenu helpMenu = new javax.swing.JMenu();
        javax.swing.JMenuItem aboutMenuItem = new javax.swing.JMenuItem();
        statusPanel = new javax.swing.JPanel();
        javax.swing.JSeparator statusPanelSeparator = new javax.swing.JSeparator();
        statusMessageLabel = new javax.swing.JLabel();
        statusAnimationLabel = new javax.swing.JLabel();
        progressBar = new javax.swing.JProgressBar();
        jPopupMenu1 = new javax.swing.JPopupMenu();
        jSeparator1 = new javax.swing.JSeparator();

        mainPanel.setName("mainPanel"); // NOI18N

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        jTextArea1.setColumns(20);
        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(heresyorigins.HeresyoriginsApp.class).getContext().getResourceMap(HeresyoriginsView.class);
        jTextArea1.setFont(resourceMap.getFont("jTextArea1.font")); // NOI18N
        jTextArea1.setLineWrap(true);
        jTextArea1.setRows(2);
        jTextArea1.setText(resourceMap.getString("jTextArea1.text")); // NOI18N
        jTextArea1.setMaximumSize(new java.awt.Dimension(32767, 32767));
        jTextArea1.setName("jTextArea1"); // NOI18N
        jScrollPane1.setViewportView(jTextArea1);

        OriginPathLabel.setLabelFor(jTextArea1);
        OriginPathLabel.setText(resourceMap.getString("OriginPathLabel.text")); // NOI18N
        OriginPathLabel.setName("OriginPathLabel"); // NOI18N

        jLabel2.setLabelFor(PathSummaryText);
        jLabel2.setText(resourceMap.getString("jLabel2.text")); // NOI18N
        jLabel2.setName("jLabel2"); // NOI18N

        jScrollPane2.setName("jScrollPane2"); // NOI18N

        PathSummaryText.setColumns(20);
        PathSummaryText.setFont(resourceMap.getFont("PathSummaryText.font")); // NOI18N
        PathSummaryText.setLineWrap(true);
        PathSummaryText.setRows(5);
        PathSummaryText.setWrapStyleWord(true);
        PathSummaryText.setMaximumSize(new java.awt.Dimension(32767, 32767));
        PathSummaryText.setName("PathSummaryText"); // NOI18N
        PathSummaryText.setPreferredSize(new java.awt.Dimension(144, 89));
        jScrollPane2.setViewportView(PathSummaryText);

        jScrollPane3.setName("jScrollPane3"); // NOI18N

        CharacterSummaryText.setColumns(20);
        CharacterSummaryText.setFont(resourceMap.getFont("CharacterSummaryText.font")); // NOI18N
        CharacterSummaryText.setLineWrap(true);
        CharacterSummaryText.setRows(5);
        CharacterSummaryText.setText(resourceMap.getString("CharacterSummaryText.text")); // NOI18N
        CharacterSummaryText.setWrapStyleWord(true);
        CharacterSummaryText.setName("CharacterSummaryText"); // NOI18N
        jScrollPane3.setViewportView(CharacterSummaryText);

        CharacterSummaryLabel.setText(resourceMap.getString("CharacterSummaryLabel.text")); // NOI18N
        CharacterSummaryLabel.setName("CharacterSummaryLabel"); // NOI18N

        ButtonPanel.setName("ButtonPanel"); // NOI18N

        HiveWorldButton.addChangeListener(changeListener);
        HiveWorldButton.setText(resourceMap.getString("HiveWorldButton.text")); // NOI18N
        HiveWorldButton.setBorder(null);
        HiveWorldButton.setName("HiveWorldButton"); // NOI18N
        HiveWorldButton.setPreferredSize(new java.awt.Dimension(80, 45));

        RogueTraderButton.addChangeListener(changeListener);
        RogueTraderButton.setText(resourceMap.getString("RogueTraderButton.text")); // NOI18N
        RogueTraderButton.setName("RogueTraderButton"); // NOI18N
        RogueTraderButton.setPreferredSize(new java.awt.Dimension(80, 45));

        VauntedButton.addChangeListener(changeListener);
        VauntedButton.setText(resourceMap.getString("VauntedButton.text")); // NOI18N
        VauntedButton.setMargin(new java.awt.Insets(2, 10, 2, 10));
        VauntedButton.setName("VauntedButton"); // NOI18N
        VauntedButton.setPreferredSize(new java.awt.Dimension(80, 45));

        CriminalButton.addChangeListener(changeListener);
        CriminalButton.setText(resourceMap.getString("CriminalButton.text")); // NOI18N
        CriminalButton.setName("CriminalButton"); // NOI18N
        CriminalButton.setPreferredSize(new java.awt.Dimension(80, 45));

        DarkVoyageButton.addChangeListener(changeListener);
        DarkVoyageButton.setText(resourceMap.getString("DarkVoyageButton.text")); // NOI18N
        DarkVoyageButton.setName("DarkVoyageButton"); // NOI18N
        DarkVoyageButton.setPreferredSize(new java.awt.Dimension(80, 45));

        TaintedButton.addChangeListener(changeListener);
        TaintedButton.setText(resourceMap.getString("TaintedButton.text")); // NOI18N
        TaintedButton.setName("TaintedButton"); // NOI18N
        TaintedButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ArchMillitantButton.addChangeListener(changeListener);
        ArchMillitantButton.setText(resourceMap.getString("ArchMillitantButton.text")); // NOI18N
        ArchMillitantButton.setBorder(javax.swing.BorderFactory.createEmptyBorder(1, 1, 1, 1));
        ArchMillitantButton.setHorizontalTextPosition(javax.swing.SwingConstants.LEADING);
        ArchMillitantButton.setName("ArchMillitantButton"); // NOI18N
        ArchMillitantButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ExploratorButton.addChangeListener(changeListener);
        ExploratorButton.setText(resourceMap.getString("ExploratorButton.text")); // NOI18N
        ExploratorButton.setName("ExploratorButton"); // NOI18N
        ExploratorButton.setPreferredSize(new java.awt.Dimension(80, 45));

        FortuneButton.addChangeListener(changeListener);
        FortuneButton.setText(resourceMap.getString("FortuneButton.text")); // NOI18N
        FortuneButton.setName("FortuneButton"); // NOI18N
        FortuneButton.setPreferredSize(new java.awt.Dimension(80, 45));

        HighVendettaButton.addChangeListener(changeListener);
        HighVendettaButton.setText(resourceMap.getString("HighVendettaButton.text")); // NOI18N
        HighVendettaButton.setName("HighVendettaButton"); // NOI18N
        HighVendettaButton.setPreferredSize(new java.awt.Dimension(80, 45));

        PrideButton.addChangeListener(changeListener);
        PrideButton.setText(resourceMap.getString("PrideButton.text")); // NOI18N
        PrideButton.setName("PrideButton"); // NOI18N
        PrideButton.setPreferredSize(new java.awt.Dimension(80, 45));

        AstropathTranscendentButton.addChangeListener(changeListener);
        AstropathTranscendentButton.setText(resourceMap.getString("AstropathTranscendentButton.text")); // NOI18N
        AstropathTranscendentButton.setActionCommand(resourceMap.getString("AstropathTranscendentButton.actionCommand")); // NOI18N
        AstropathTranscendentButton.setBorder(null);
        AstropathTranscendentButton.setHideActionText(true);
        AstropathTranscendentButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        AstropathTranscendentButton.setMargin(new java.awt.Insets(0, 0, 0, 0));
        AstropathTranscendentButton.setMaximumSize(new java.awt.Dimension(66, 15));
        AstropathTranscendentButton.setName("AstropathTranscendentButton"); // NOI18N
        AstropathTranscendentButton.setPreferredSize(new java.awt.Dimension(80, 45));

        VengeanceButton.addChangeListener(changeListener);
        VengeanceButton.setText(resourceMap.getString("VengeanceButton.text")); // NOI18N
        VengeanceButton.setName("VengeanceButton"); // NOI18N
        VengeanceButton.setPreferredSize(new java.awt.Dimension(80, 45));

        TheHandOfWarButton.addChangeListener(changeListener);
        TheHandOfWarButton.setText(resourceMap.getString("TheHandOfWarButton.label")); // NOI18N
        TheHandOfWarButton.setMargin(new java.awt.Insets(2, 10, 2, 10));
        TheHandOfWarButton.setName("TheHandOfWarButton"); // NOI18N
        TheHandOfWarButton.setPreferredSize(new java.awt.Dimension(80, 45));

        NavigatorButton.addChangeListener(changeListener);
        NavigatorButton.setText(resourceMap.getString("NavigatorButton.text")); // NOI18N
        NavigatorButton.setName("NavigatorButton"); // NOI18N
        NavigatorButton.setPreferredSize(new java.awt.Dimension(80, 45));

        NobleBornButton.addChangeListener(changeListener);
        NobleBornButton.setText(resourceMap.getString("NobleBornButton.text")); // NOI18N
        NobleBornButton.setActionCommand(resourceMap.getString("NobleBornButton.actionCommand")); // NOI18N
        NobleBornButton.setAlignmentX(0.5F);
        NobleBornButton.setBorder(null);
        NobleBornButton.setName("NobleBornButton"); // NOI18N
        NobleBornButton.setPreferredSize(new java.awt.Dimension(80, 45));

        VoidBornButton.addChangeListener(changeListener);
        VoidBornButton.setText(resourceMap.getString("VoidBornButton.text")); // NOI18N
        VoidBornButton.setActionCommand(resourceMap.getString("VoidBornButton.actionCommand")); // NOI18N
        VoidBornButton.setBorder(null);
        VoidBornButton.setName("VoidBornButton"); // NOI18N
        VoidBornButton.setPreferredSize(new java.awt.Dimension(80, 45));

        SavantButton.addChangeListener(changeListener);
        SavantButton.setText(resourceMap.getString("SavantButton.text")); // NOI18N
        SavantButton.setName("SavantButton"); // NOI18N
        SavantButton.setPreferredSize(new java.awt.Dimension(80, 45));

        PressGangnedButton.addChangeListener(changeListener);
        PressGangnedButton.setText(resourceMap.getString("PressGangnedButton.text")); // NOI18N
        PressGangnedButton.setName("PressGangnedButton"); // NOI18N
        PressGangnedButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ChildOfTheCreedButton.addChangeListener(changeListener);
        ChildOfTheCreedButton.setText(resourceMap.getString("ChildOfTheCreedButton.text")); // NOI18N
        ChildOfTheCreedButton.setMargin(new java.awt.Insets(2, 8, 2, 8));
        ChildOfTheCreedButton.setName("ChildOfTheCreedButton"); // NOI18N
        ChildOfTheCreedButton.setPreferredSize(new java.awt.Dimension(80, 45));

        DeathWorldButton.addChangeListener(changeListener);
        DeathWorldButton.setText(resourceMap.getString("DeathWorldButton.text")); // NOI18N
        DeathWorldButton.setBorder(null);
        DeathWorldButton.setName("Death World"); // NOI18N
        DeathWorldButton.setPreferredSize(new java.awt.Dimension(80, 45));

        StubjackButton.addChangeListener(changeListener);
        StubjackButton.setText(resourceMap.getString("StubjackButton.text")); // NOI18N
        StubjackButton.setMargin(new java.awt.Insets(2, 14, 2, 10));
        StubjackButton.setName("StubjackButton"); // NOI18N
        StubjackButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ShipLornButton.addChangeListener(changeListener);
        ShipLornButton.setText(resourceMap.getString("ShipLornButton.text")); // NOI18N
        ShipLornButton.setName("ShipLornButton"); // NOI18N
        ShipLornButton.setPreferredSize(new java.awt.Dimension(80, 45));

        RenegadeButton.addChangeListener(changeListener);
        RenegadeButton.setText(resourceMap.getString("RenegadeButton.text")); // NOI18N
        RenegadeButton.setName("RenegadeButton"); // NOI18N
        RenegadeButton.setPreferredSize(new java.awt.Dimension(80, 45));

        CalamityButton.addChangeListener(changeListener);
        CalamityButton.setText(resourceMap.getString("CalamityButton.text")); // NOI18N
        CalamityButton.setName("CalamityButton"); // NOI18N
        CalamityButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ScapegraceButton.addChangeListener(changeListener);
        ScapegraceButton.setText(resourceMap.getString("ScapegraceButton.text")); // NOI18N
        ScapegraceButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
        ScapegraceButton.setName("ScapegraceButton"); // NOI18N
        ScapegraceButton.setPreferredSize(new java.awt.Dimension(80, 45));

        SeneschalButton.addChangeListener(changeListener);
        SeneschalButton.setText(resourceMap.getString("SeneschalButton.text")); // NOI18N
        SeneschalButton.setName("SeneschalButton"); // NOI18N
        SeneschalButton.setPreferredSize(new java.awt.Dimension(80, 45));

        RenownButton.addChangeListener(changeListener);
        RenownButton.setText(resourceMap.getString("RenownButton.text")); // NOI18N
        RenownButton.setName("RenownButton"); // NOI18N
        RenownButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ScavengerButton.addChangeListener(changeListener);
        ScavengerButton.setText(resourceMap.getString("ScavengerButton.text")); // NOI18N
        ScavengerButton.setComponentPopupMenu(jPopupMenu1);
        ScavengerButton.setMargin(new java.awt.Insets(2, 8, 2, 8));
        ScavengerButton.setName("ScavengerButton"); // NOI18N
        ScavengerButton.setPreferredSize(new java.awt.Dimension(80, 45));

        DutyBoundButton.addChangeListener(changeListener);
        DutyBoundButton.setText(resourceMap.getString("DutyBoundButton.text")); // NOI18N
        DutyBoundButton.setBorder(null);
        DutyBoundButton.setName("DutyBoundButton"); // NOI18N
        DutyBoundButton.setPreferredSize(new java.awt.Dimension(80, 45));

        PrestigeButton.addChangeListener(changeListener);
        PrestigeButton.setText(resourceMap.getString("PrestigeButton.text")); // NOI18N
        PrestigeButton.setName("PrestigeButton"); // NOI18N
        PrestigeButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ImperialWorldButton.addChangeListener(changeListener);
        ImperialWorldButton.setText(resourceMap.getString("ImperialWorldButton.text")); // NOI18N
        ImperialWorldButton.setBorder(null);
        ImperialWorldButton.setName("ImperialWorldButton"); // NOI18N
        ImperialWorldButton.setPreferredSize(new java.awt.Dimension(80, 45));

        VoidMasterButton.addChangeListener(changeListener);
        VoidMasterButton.setText(resourceMap.getString("VoidMasterButton.text")); // NOI18N
        VoidMasterButton.setName("VoidMasterButton"); // NOI18N
        VoidMasterButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ZealotButton.addChangeListener(changeListener);
        ZealotButton.setText(resourceMap.getString("ZealotButton.text")); // NOI18N
        ZealotButton.setName("ZealotButton"); // NOI18N
        ZealotButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ChosenByDestinyButton.addChangeListener(changeListener);
        ChosenByDestinyButton.setText(resourceMap.getString("ChosenByDestinyButton.text")); // NOI18N
        ChosenByDestinyButton.setMargin(new java.awt.Insets(2, 8, 2, 8));
        ChosenByDestinyButton.setName("ChosenByDestinyButton"); // NOI18N
        ChosenByDestinyButton.setPreferredSize(new java.awt.Dimension(80, 45));

        MissionaryButton.addChangeListener(changeListener);
        MissionaryButton.setText(resourceMap.getString("MissionaryButton.text")); // NOI18N
        MissionaryButton.setName("MissionaryButton"); // NOI18N
        MissionaryButton.setPreferredSize(new java.awt.Dimension(80, 45));

        ForgeWorldButton.addChangeListener(changeListener);
        ForgeWorldButton.setText(resourceMap.getString("ForgeWorldButton.text")); // NOI18N
        ForgeWorldButton.setBorder(null);
        ForgeWorldButton.setName("ForgeWorldButton"); // NOI18N
        ForgeWorldButton.setPreferredSize(new java.awt.Dimension(80, 45));

        EnduranceButton.addChangeListener(changeListener);
        EnduranceButton.setText(resourceMap.getString("EnduranceButton.text")); // NOI18N
        EnduranceButton.setName("EnduranceButton"); // NOI18N
        EnduranceButton.setPreferredSize(new java.awt.Dimension(80, 45));

        OptionsButton.setText(resourceMap.getString("OptionsButton.text")); // NOI18N
        OptionsButton.setAlignmentX(0.5F);
        OptionsButton.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));
        OptionsButton.setEnabled(false);
        OptionsButton.setName("OptionsButton"); // NOI18N

        javax.swing.GroupLayout ButtonPanelLayout = new javax.swing.GroupLayout(ButtonPanel);
        ButtonPanel.setLayout(ButtonPanelLayout);
        ButtonPanelLayout.setHorizontalGroup(
            ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(ButtonPanelLayout.createSequentialGroup()
                .addGap(11, 11, 11)
                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(ButtonPanelLayout.createSequentialGroup()
                        .addComponent(OptionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, 69, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(ButtonPanelLayout.createSequentialGroup()
                                .addComponent(DeathWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(VoidBornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(ForgeWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(HiveWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(ImperialWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(NobleBornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(ButtonPanelLayout.createSequentialGroup()
                                .addComponent(TheHandOfWarButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(PressGangnedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(CalamityButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(ShipLornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(DarkVoyageButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(HighVendettaButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(ButtonPanelLayout.createSequentialGroup()
                                .addComponent(EnduranceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(FortuneButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(VengeanceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(RenownButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(PrideButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(PrestigeButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(ButtonPanelLayout.createSequentialGroup()
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, ButtonPanelLayout.createSequentialGroup()
                                        .addComponent(ScavengerButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(ScapegraceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(StubjackButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(ChildOfTheCreedButton, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, ButtonPanelLayout.createSequentialGroup()
                                        .addComponent(TaintedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(CriminalButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(RenegadeButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                        .addComponent(DutyBoundButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(ButtonPanelLayout.createSequentialGroup()
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(ZealotButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(ChosenByDestinyButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, ButtonPanelLayout.createSequentialGroup()
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(SavantButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(VauntedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))))
                    .addGroup(ButtonPanelLayout.createSequentialGroup()
                        .addComponent(AstropathTranscendentButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(ArchMillitantButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(VoidMasterButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(ExploratorButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(MissionaryButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(SeneschalButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(NavigatorButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(RogueTraderButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        ButtonPanelLayout.setVerticalGroup(
            ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(ButtonPanelLayout.createSequentialGroup()
                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(ButtonPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(ButtonPanelLayout.createSequentialGroup()
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER)
                                    .addComponent(ImperialWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(NobleBornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(ScavengerButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(ScapegraceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(StubjackButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(SavantButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(VauntedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addComponent(ChildOfTheCreedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(TaintedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(CriminalButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(RenegadeButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(ZealotButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addComponent(ChosenByDestinyButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(DutyBoundButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(CalamityButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(ShipLornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(TheHandOfWarButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(PressGangnedButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(HighVendettaButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(DarkVoyageButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(EnduranceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(FortuneButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(RenownButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(VengeanceButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(PrideButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addComponent(PrestigeButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                            .addComponent(HiveWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                .addComponent(VoidBornButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addComponent(ForgeWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(DeathWorldButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(ButtonPanelLayout.createSequentialGroup()
                        .addGap(31, 31, 31)
                        .addComponent(OptionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, 59, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addComponent(AstropathTranscendentButton, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(ArchMillitantButton, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(RogueTraderButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGroup(ButtonPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(SeneschalButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(NavigatorButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(MissionaryButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(ExploratorButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(VoidMasterButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        VoidBornButton.getAccessibleContext().setAccessibleName(resourceMap.getString("VoidBornButton.AccessibleContext.accessibleName")); // NOI18N

        javax.swing.GroupLayout mainPanelLayout = new javax.swing.GroupLayout(mainPanel);
        mainPanel.setLayout(mainPanelLayout);
        mainPanelLayout.setHorizontalGroup(
            mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(mainPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(ButtonPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 728, Short.MAX_VALUE)
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 728, Short.MAX_VALUE)
                    .addComponent(jLabel2)
                    .addComponent(OriginPathLabel)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 728, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(mainPanelLayout.createSequentialGroup()
                        .addComponent(CharacterSummaryLabel)
                        .addContainerGap(20, Short.MAX_VALUE))
                    .addComponent(jScrollPane3, javax.swing.GroupLayout.DEFAULT_SIZE, 115, Short.MAX_VALUE)))
        );
        mainPanelLayout.setVerticalGroup(
            mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(mainPanelLayout.createSequentialGroup()
                .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, mainPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(ButtonPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(OriginPathLabel)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel2)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 195, Short.MAX_VALUE))
                    .addGroup(mainPanelLayout.createSequentialGroup()
                        .addGap(11, 11, 11)
                        .addComponent(CharacterSummaryLabel)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane3, javax.swing.GroupLayout.DEFAULT_SIZE, 589, Short.MAX_VALUE)))
                .addContainerGap())
        );

        menuBar.setName("menuBar"); // NOI18N

        fileMenu.setText(resourceMap.getString("fileMenu.text")); // NOI18N
        fileMenu.setName("fileMenu"); // NOI18N

        javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance(heresyorigins.HeresyoriginsApp.class).getContext().getActionMap(HeresyoriginsView.class, this);
        ListM.setAction(actionMap.get("ChangeMethodVisible")); // NOI18N
        ListM.setText(resourceMap.getString("ListM.text")); // NOI18N
        ListM.setName("ListM"); // NOI18N
        fileMenu.add(ListM);

        exitMenuItem.setAction(actionMap.get("quit")); // NOI18N
        exitMenuItem.setName("exitMenuItem"); // NOI18N
        fileMenu.add(exitMenuItem);

        menuBar.add(fileMenu);

        helpMenu.setText(resourceMap.getString("helpMenu.text")); // NOI18N
        helpMenu.setName("helpMenu"); // NOI18N

        aboutMenuItem.setAction(actionMap.get("showAboutBox")); // NOI18N
        aboutMenuItem.setName("aboutMenuItem"); // NOI18N
        helpMenu.add(aboutMenuItem);

        menuBar.add(helpMenu);

        statusPanel.setName("statusPanel"); // NOI18N

        statusPanelSeparator.setName("statusPanelSeparator"); // NOI18N

        statusMessageLabel.setName("statusMessageLabel"); // NOI18N

        statusAnimationLabel.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
        statusAnimationLabel.setName("statusAnimationLabel"); // NOI18N

        progressBar.setName("progressBar"); // NOI18N

        javax.swing.GroupLayout statusPanelLayout = new javax.swing.GroupLayout(statusPanel);
        statusPanel.setLayout(statusPanelLayout);
        statusPanelLayout.setHorizontalGroup(
            statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(statusPanelSeparator, javax.swing.GroupLayout.DEFAULT_SIZE, 859, Short.MAX_VALUE)
            .addGroup(statusPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(statusMessageLabel)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 689, Short.MAX_VALUE)
                .addComponent(progressBar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(statusAnimationLabel)
                .addContainerGap())
        );
        statusPanelLayout.setVerticalGroup(
            statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(statusPanelLayout.createSequentialGroup()
                .addComponent(statusPanelSeparator, javax.swing.GroupLayout.PREFERRED_SIZE, 2, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(statusMessageLabel)
                    .addComponent(statusAnimationLabel)
                    .addComponent(progressBar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(3, 3, 3))
        );

        jPopupMenu1.setComponentPopupMenu(jPopupMenu1);
        jPopupMenu1.setName("jPopupMenu1"); // NOI18N

        jSeparator1.setName("jSeparator1"); // NOI18N
        jPopupMenu1.add(jSeparator1);

        setComponent(mainPanel);
        setMenuBar(menuBar);
        setStatusBar(statusPanel);
    }// </editor-fold>//GEN-END:initComponents

    @Action
    public void ChangeMethodVisible() {
    if (ButtonPanel.isVisible()) {ButtonPanel.setVisible(false);
    }else{ ButtonPanel.setVisible(true);}}

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JToggleButton ArchMillitantButton;
    private javax.swing.JToggleButton AstropathTranscendentButton;
    private javax.swing.JPanel ButtonPanel;
    private javax.swing.JToggleButton CalamityButton;
    private javax.swing.JLabel CharacterSummaryLabel;
    private javax.swing.JTextArea CharacterSummaryText;
    private javax.swing.JToggleButton ChildOfTheCreedButton;
    private javax.swing.JToggleButton ChosenByDestinyButton;
    private javax.swing.JToggleButton CriminalButton;
    private javax.swing.JToggleButton DarkVoyageButton;
    private javax.swing.JToggleButton DeathWorldButton;
    private javax.swing.JToggleButton DutyBoundButton;
    private javax.swing.JToggleButton EnduranceButton;
    private javax.swing.JToggleButton ExploratorButton;
    private javax.swing.JToggleButton ForgeWorldButton;
    private javax.swing.JToggleButton FortuneButton;
    private javax.swing.JToggleButton HighVendettaButton;
    private javax.swing.JToggleButton HiveWorldButton;
    private javax.swing.JToggleButton ImperialWorldButton;
    private javax.swing.JMenuItem ListM;
    private javax.swing.JToggleButton MissionaryButton;
    private javax.swing.JToggleButton NavigatorButton;
    private javax.swing.JToggleButton NobleBornButton;
    private javax.swing.JButton OptionsButton;
    private javax.swing.JLabel OriginPathLabel;
    private javax.swing.JTextArea PathSummaryText;
    private javax.swing.JToggleButton PressGangnedButton;
    private javax.swing.JToggleButton PrestigeButton;
    private javax.swing.JToggleButton PrideButton;
    private javax.swing.JToggleButton RenegadeButton;
    private javax.swing.JToggleButton RenownButton;
    private javax.swing.JToggleButton RogueTraderButton;
    private javax.swing.JToggleButton SavantButton;
    private javax.swing.JToggleButton ScapegraceButton;
    private javax.swing.JToggleButton ScavengerButton;
    private javax.swing.JToggleButton SeneschalButton;
    private javax.swing.JToggleButton ShipLornButton;
    private javax.swing.JToggleButton StubjackButton;
    private javax.swing.JToggleButton TaintedButton;
    private javax.swing.JToggleButton TheHandOfWarButton;
    private javax.swing.JToggleButton VauntedButton;
    private javax.swing.JToggleButton VengeanceButton;
    private javax.swing.JToggleButton VoidBornButton;
    private javax.swing.JToggleButton VoidMasterButton;
    private javax.swing.JToggleButton ZealotButton;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JPopupMenu jPopupMenu1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JTextArea jTextArea1;
    private javax.swing.JPanel mainPanel;
    private javax.swing.JMenuBar menuBar;
    private javax.swing.JProgressBar progressBar;
    private javax.swing.JLabel statusAnimationLabel;
    private javax.swing.JLabel statusMessageLabel;
    private javax.swing.JPanel statusPanel;
    // End of variables declaration//GEN-END:variables

    private final Timer messageTimer;
    private final Timer busyIconTimer;
    private final Icon idleIcon;
    private final Icon[] busyIcons = new Icon[15];
    private int busyIconIndex = 0;
    private String Text = "";
    private JDialog aboutBox;

}
